Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable travis to run tests #154

Merged
merged 1 commit into from
Mar 21, 2016
Merged

Conversation

kokosing
Copy link
Contributor

Enable travis to run tests

Fixes #151.

@losipiuk
Copy link
Contributor

looks good

1 similar comment
@cawallin
Copy link
Member

looks good

@cawallin
Copy link
Member

Can travis handle a ~2h test run with 4 docker containers?

@mattsfuller
Copy link

@rschlussel-zz
Copy link
Member

we could run just the smoketest

@mattsfuller
Copy link

That's a good idea to start.

kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
@kokosing
Copy link
Contributor Author

See travis build for current configuration: https://travis-ci.org/Teradata/presto-admin/jobs/116648638

kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
@kokosing
Copy link
Contributor Author

kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 17, 2016
@kokosing
Copy link
Contributor Author

kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 18, 2016
Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 18, 2016
Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 18, 2016
Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 18, 2016
Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 18, 2016
Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
@kokosing
Copy link
Contributor Author

Travis build passes: https://travis-ci.org/Teradata/presto-admin/builds/116847168

@cawallin @mattsfuller @rschlussel Please review this PR one more time.
Travis run 9 jobs, 8 runs product test and one rest. Using online installer requires more time to test. Product tests are distributed between travis jobs by files ordered by its length in round robin fashion.

@rschlussel-zz
Copy link
Member

looks good

1 similar comment
@cawallin
Copy link
Member

looks good

install:
- pip install --upgrade pip==6.1.1
- pip install -r requirements.txt
script:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just pushed #160 so that when we have future infra issues, we don't fail to build the base image for every test case. This means that the base image needs to be built prior to running the test cases. You can do this with make docker-images, I took a quick look at the travis docs, it looks like that should happen in a before-script section so that if it fails we won't try to run the product tests.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, so now product test execution should take less time, shouldn't it?

script:
- |
if [ -v PRODUCT_TEST_GROUP ]; then
PRODUCT_TESTS=$(find tests/product/ -name '*py' | grep -v __init__ | xargs wc -l | sort -n | head -n -1 | awk '{print $2}' | awk "NR % 8 == $PRODUCT_TEST_GROUP" | tr '\n' ' ')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest combining the last two awk commands into awk "NR % 8 == $PRODUCT_TEST_GROUP { print $2 }", but it's up to you.

Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
@kokosing kokosing merged commit 2907278 into prestodb:master Mar 21, 2016
@kokosing kokosing deleted the feature_travis branch March 21, 2016 07:41
kokosing added a commit to Teradata/presto-admin that referenced this pull request Mar 21, 2016
Product tests will be using online installer. This is possible by
setting PA_TEST_ONLINE_INSTALLER environment variable and using it in
prestoadmin_installer.py to select installer.

Fixes prestodb#151.

Pull request: prestodb#154
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants